/**
 * @namespace
 * @desc SC 은행 Common 라이브러리의 Topic 네임스페이스
 */
ScLibs.Topic = {

};

(function(){
// documentation: http://amplifyjs.com/api/pubsub/

/**
 * @function
 * @memberof ScLibs.Topic
 * @param {String} topic
 * @param [...] Zero or more parameters.
 * @desc Publish a topic.
 * @example
 * ScLibs.Topic.publish('topic');
 * @example
 * ScLibs.Topic.publish('topic', 42, true, 'string', {});
 */
ScLibs.Topic.publish = function (topic /* , ... */) {
    return amplify.publish.apply(this, arguments);
};

/**
 * @function
 * @memberof ScLibs.Topic
 * @param {String} topic
 * @param {Function} callback.
 * @desc Subscribe to a topic.
 * @example
 * ScLibs.Topic.subscribe('topic', console.log);
 * @example
 * ScLibs.Topic.subscribe('topic', function (param1, param2) {
 *     console.log(param1, param2);
 * });
 */
ScLibs.Topic.subscribe = function (topic /* , ... */) {
    return amplify.subscribe.apply(this, arguments);
};

/**
 * @function
 * @memberof ScLibs.Topic
 * @param {String} topic
 * @param {Function} callback.
 * @desc Subscribe to a topic.
 * @example
 * ScLibs.Topic.unsubscribe('topic', console.log);
 */
ScLibs.Topic.unsubscribe = function (topic, callback) {
    return amplify.unsubscribe.apply(this, arguments);
};

}());

